# -*- coding: utf-8 -*-
"""
date: Mon Dec 17 11:28:59 2018
python: Anaconda 3.6.5
author: kanade
email: kanade@blisst.cn
"""
import numpy as np
import matplotlib.pyplot as mp


t = np.linspace(0, 6 * np.pi, 1000)
spiral = t
rose = 10 * np.sin(6 * t) # sin(nx),n是叶的个数

mp.figure('Polar', facecolor='lightgray')
mp.gca(projection='polar')  # 创建极坐标系
mp.title('Polar', fontsize=20)

mp.grid(linestyle=':')
mp.plot(t, spiral, c='dodgerblue',
        label=r'$\rho=\theta$')
mp.plot(t, rose, c='orangered',
        label=r'$\rho=10sin(6\theta)$')


mp.legend()
mp.show()
